<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
    <th:block th:include="include :: header('督办处理列表')" />
    <th:block th:include="include :: header('弹层组件')" />
</head>
<body class="gray-bg">
     <div class="container-div">
        <div class="row">
            <div class="col-sm-12 search-collapse">
                <form id="formId">
                    <div class="select-list">
                        <ul>
                            <li class="select-time">
                                <p>交易日期：</p>
                                <input type="text" class="time-input" id="startTime" placeholder="开始时间" name="beginTrDate"/>
                                <span>-</span>
                                <input type="text" class="time-input" id="endTime" placeholder="结束时间" name="endTrDate"/>
                            </li>
                            <li class="select-time">
                                <p>整改期限：</p>
                                <input type="text" class="time-input" id="startTime" placeholder="开始时间" name="beginCorrectLimitDate"/>
                                <span>-</span>
                                <input type="text" class="time-input" id="endTime" placeholder="结束时间" name="endCorrectLimitDate"/>
                            </li>
                            <li>
                                <p>机构号：</p>
                                <input type="text" name="orgId"/>
                            </li>
                            <li>
                                <p>柜员号：</p>
                                <input type="text" name="tellerId"/>
                            </li>
                            <li>
                                <p>交易流水：</p>
                                <input type="text" name="vchNo"/>
                            </li>
                            <li>
                                <p>流水标志：</p>
                                <select name="vchFlag" th:with="type=${@dict.getType('vch_flag')}">
                                    <option value="">所有</option>
                                    <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
                                </select>
                            </li>
                            <li>
                                <p>督办编号：</p>
                                <input type="text" name="code"/>
                            </li>
                            <li>
                                <p>创建人：</p>
                                <input type="text" name="errRegOper"/>
                            </li>
                            <li>
                                <p>差错类型：</p>
                                <input type="text" name="errTypeId"/>
                            </li>
                            <li>
                                <p>差错等级：</p>
                                <input type="text" name="errGrade"/>
                            </li>
                            <li>
                                <p>差错状态：</p>
                                <select name="errStatus" th:with="type=${@dict.getType('err_status')}">
                                    <option value="">所有</option>
                                    <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
                                </select>
                            </li>

                            <li>
                                <p>整改标志：</p>
                                <select name="correctFlag" th:with="type=${@dict.getType('correct_flag')}">
                                    <option value="">所有</option>
                                    <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
                                </select>
                            </li>
                            <li>
                                <p>是否超期：</p>
                                <select name="correctOvertime" th:with="type=${@dict.getType('sys_y_n')}">
                                    <option value="">所有</option>
                                    <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
                                </select>
                            </li>
                            <li>
                                <p>回复标志：</p>
                                <select name="replyFlag" th:with="type=${@dict.getType('reply_flag')}">
                                    <option value="">所有</option>
                                    <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
                                </select>
                            </li>
                            <li>
                                <p>督办次数：</p>
                                <input type="text" name="times"/>
                            </li>
                            <li>
                                <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
                                <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
                            </li>
                        </ul>
                    </div>
                </form>
            </div>

            <div class="btn-group-sm" id="toolbar" role="group">
                <a class="btn btn-success" onclick="doProcessError('8a28d08f2b2b08b81323599f22c9b529')" shiro:hasPermission="er:PaeaErErrorProcess:doProcessErrorPre">
                    <i class="fa fa-plus"></i> 处理
                </a>
                <a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="er:paeaErErrorProcess:remove">
                    <i class="fa fa-remove"></i> 删除
                </a>

            </div>
            <div class="col-sm-12 select-table table-striped">
                <table id="bootstrap-table"></table>
            </div>
        </div>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        var editFlag = [[${@permission.hasPermi('er:paeaErErrorProcess:processErrorPre')}]];
        var removeFlag = [[${@permission.hasPermi('er:paeaErErrorProcess:remove')}]];
        var vchFlagDatas = [[${@dict.getType('vch_flag')}]];
        var errSourceDatas = [[${@dict.getType('err_source')}]];
        var errStatusDatas = [[${@dict.getType('err_status')}]];
        var correctFlagDatas = [[${@dict.getType('correct_flag')}]];
        var correctOvertimeDatas = [[${@dict.getType('sys_y_n')}]];
        var replyFlagDatas = [[${@dict.getType('reply_flag')}]];
        var prefix = ctx + "er/paeaErErrorProcess";
        var prefixEr = ctx + "er/paeaErError";

        $(function() {
            var options = {
                url: prefix + "/list",
                updateUrl: prefix + "/edit/{id}",
                removeUrl: prefix + "/remove",
                exportUrl: prefix + "/export",
                detailUrl: prefix + "/doProcessError",
                modalName: "督办处理",
                //启用跳转至指定页
                showPageGo: true,
                //启用点击选中行
                clickToSelect: true,
                columns: [{
                    radio: true
                },
                {
                    field : 'id', 
                    title : '主键',
                    visible: false
                },
                {
                    field : 'code', 
                    title : '督办编号'
                },
                {
                    field : 'name', 
                    title : '督办名称',
                    visible: false
                },
                {
                    field : 'description', 
                    title : '差错描述',
                    visible: false
                },
                {
                    field : 'trDate', 
                    title : '交易日期'
                },
                {
                    field : 'orgId', 
                    title : '机构号'
                },
                {
                    field : 'orgName', 
                    title : '机构名称'
                },
                {
                    field : 'tellerId', 
                    title : '柜员号'
                },
                {
                    field : 'tellerName', 
                    title : '柜员姓名'
                },
                {
                    field : 'vchNo', 
                    title : '交易流水'
                },
                {
                    field : 'vchFlag', 
                    title : '流水标志',
                    formatter: function(value, row, index) {
                       return $.table.selectDictLabel(vchFlagDatas, value);
                    }
                },
                {
                    field : 'auCode', 
                    title : '监控项编号',
                    visible: false
                },
                {
                    field : 'auName', 
                    title : '监控项名称',
                    visible: false
                },
                {
                    field : 'auditOrg', 
                    title : '监督中心',
                    visible: false
                },
                {
                    field : 'title', 
                    title : '标题',
                    visible: false
                },
                {
                    field : 'errTitle', 
                    title : '督办标题'
                },
                {
                    field : 'notifyDate', 
                    title : '下发日期'
                },
                {
                    field : 'notifyNum', 
                    title : '下发次数'
                },
                {
                    field : 'auditProceeding', 
                    title : '监督事项',
                    visible: false
                },
                {
                    field : 'auditSuggest', 
                    title : '整改建议',
                    visible: false
                },
                {
                    field : 'curRoleId', 
                    title : '当前角色',
                    visible: false
                },
                {
                    field : 'errRegOper', 
                    title : '创建人'
                },
                {
                    field : 'errSource', 
                    title : '督办类型',
                    visible: false,
                    formatter: function(value, row, index) {
                       return $.table.selectDictLabel(errSourceDatas, value);
                    }
                },
                {
                    field : 'errTypeId', 
                    title : '差错类型',
                    visible: false
                },
                {
                    field : 'errGrade', 
                    title : '差错等级',
                    visible: false
                },
                {
                    field : 'errState', 
                    title : '状态'
                },
                {
                    field : 'errAuditor', 
                    title : '产生差错监督员',
                    visible: false
                },
                {
                    field : 'correctLimitDate', 
                    title : '整改期限'
                },
                {
                    field : 'correctDate', 
                    title : '整改日期',
                    visible: false
                },
                {
                    field : 'correctVchNo', 
                    title : '整改交易流水号',
                    visible: false
                },
                {
                    field : 'correctOper', 
                    title : '整改人',
                    visible: false
                },
                {
                    field : 'correctFlag', 
                    title : '整改标志',
                    visible: false,
                    formatter: function(value, row, index) {
                       return $.table.selectDictLabel(correctFlagDatas, value);
                    }
                },
                {
                    field : 'correctOvertime', 
                    title : '是否超期',
                    formatter: function(value, row, index) {
                       return $.table.selectDictLabel(correctOvertimeDatas, value);
                    }
                },
                {
                    field : 'responsibleOper', 
                    title : '负责人',
                    visible: false
                },
                {
                    field : 'replyDate', 
                    title : '回复日期',
                    visible: false
                },
                {
                    field : 'replyOper', 
                    title : '回复人',
                    visible: false
                },
                {
                    field : 'replyFlag', 
                    title : '回复标志',
                    formatter: function(value, row, index) {
                       return $.table.selectDictLabel(replyFlagDatas, value);
                    }
                },
                {
                    field : 'replyContent', 
                    title : '回复内容',
                    visible: false
                },
                {
                    field : 'replyComments', 
                    title : '回复意见',
                    visible: false
                },
                {
                    field : 'initRespOper', 
                    title : '初始负责人',
                    visible: false
                },
                {
                    field : 'handoverOper', 
                    title : '接收人',
                    visible: false
                },
                {
                    field : 'opFlag', 
                    title : '处理标志',
                    visible: false
                },
                {
                    field : 'acquiredTime', 
                    title : '获取时间',
                    visible: false
                },
                {
                    field : 'acquiredStatus', 
                    title : '获取状态',
                    visible: false
                },
                {
                    field : 'times', 
                    title : '督办次数'
                },
                {
                    field : 'exclusiveOper', 
                    title : '排除人',
                    visible: false
                },
                {
                    field : 'reviewId', 
                    title : '复核员ID',
                    visible: false
                },
                {
                    field : 'reviewName', 
                    title : '复核员姓名',
                    visible: false
                },
                {
                    field : 'authId', 
                    title : '授权人ID',
                    visible: false
                },
                {
                    field : 'authName', 
                    title : '授权人姓名',
                    visible: false
                },
                {
                    field : 'reason', 
                    title : '差错原因',
                    visible: false
                },
                {
                    field : 'reasonCode', 
                    title : '原因编码',
                    visible: false
                },
                {
                    field : 'reasonFlag', 
                    title : '未用',
                    visible: false
                },
                {
                    title: '操作',
                    align: 'center',
                    formatter: function(value, row, index) {
                        var actions = [];
                        actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="doProcessError(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> ');
                        return actions.join('');
                    }
                }]
            };
            $.table.init(options);
        });
        //演示方法 重点监督为例子
        function doProcessError(errId){
            var url =  ctx  + 'er/paeaErErrorProcess/doProcessErrorPre?id='+errId;
           // $.modal.openFull("督办处理", url);
           // $.modal.parentTab("督办处理", url);
            $.modal.openFullNoTitle("督办处理", url,document.body.clientWidth,document.body.clientHeight);

        }
    </script>
</body>
</html>